This is a step-by-step guide, describing the needed steps to reuse a library built with the Xcode Maven Plugin
Your project specifies a dependency to the dependent library to use in the dependencies section of the pom.xml.
<dependency> <groupId>com.sap.tip.production.prototype.xcodeprojects</groupId> <artifactId>MyLib</artifactId> <version>1.0.0-SNAPSHOT</version> <type>xcode-lib</type> </dependency>
Additionally you have to link the library in your XCode project as usual:
Objective-C does not define linker symbols for each function (or method, in Objective-C) - instead, linker symbols are only generated for each class. If you extend a pre existing class with categories, the linker does not know to associate the object code of the core class implementation and the category implementation. This prevents objects created in the resulting application from responding to a selector that is defined in the category. Detailed information can be found here: https://developer.apple.com/library/mac/#qa/qa1490/_index.html
To resolve this issue, the target linking against the static library must pass the -ObjC option to the linker. This flag causes the linker to load every object file in the library that defines an Objective-C class or category.